<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateDicitemsTable extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        Schema::create('dicitems', function (Blueprint $table) {
//            $table->comment('字典详情');
            $table->bigIncrements('id');
            $table->string('diccode', 30)->comment('字典编码');
            $table->string('itemcode', 30)->comment('条目编码');
            $table->string('itemname', 60)->comment('条目名称');
            $table->string('itemmemo', 100)->nullable()->comment('条目备注');
            $table->bigInteger('sortnum')->default(50)->comment('排序');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::dropIfExists('dicitems');
    }
};
